<div class="comment">
    <h2>评论</h2>
    <foreach name="comments" item="vo">
        <div class="comment-body" style="border: 1px gray solid;margin: 5px;padding: 5px;">
            <span>{$vo.full_name}</span>
            &nbsp;&nbsp;&nbsp;&nbsp;
            <span class="time">{:date('Y-m-d H:i:s',$vo['create_time'])}</span>
            &nbsp;&nbsp;&nbsp;&nbsp;
            <button onclick="$('#reply-{$vo.id}').toggle()">回复</button>
            <div class="comment-content">
                {$vo.content}
                <form class="comment-reply-box" action="{:cmf_plugin_url('PostComment://Index/insertComment')}" method="POST" id="reply-{$vo.id}" style="display: none">
                    <input type="hidden" name="object_id" value="{$object_id}">
                    <input type="hidden" name="table_name" value="{$table_name}">
                    <input type="hidden" name="parent_id" value="{$vo.id}">
                    <input type="hidden" name="to_user_id" value="{$vo.user_id}">
                    <textarea class="textbox" placeholder="请输入要回复内容" name="content"></textarea>
                    <button type="submit">发送</button>
                </form>
            </div>
        </div>
    </foreach>
    <div class="comment-postbox-wraper">
        <form class="comment-postbox" action="{:cmf_plugin_url('PostComment://Index/insertComment')}" method="POST">
            <input type="hidden" name="object_id" value="{$object_id}">
            <input type="hidden" name="table_name" value="{$table_name}">
            <div class="comment-reply-box">
                <textarea class="textbox" placeholder="请输入要回复内容" name="content"></textarea>
                <button class="comment-reply-submit btn" type="submit">发送</button>
            </div>
        </form>
    </div>
</div>